package com.ternnetwork.core.service;

import java.io.OutputStream;

import org.apache.poi.hssf.usermodel.HSSFWorkbook;

import com.ternnetwork.commons.model.http.BaseResponse;
import com.ternnetwork.persistence.page.Page;
import com.ternnetwork.core.entity.User;




public interface UserService {
	public Page<User> query(User t,Page page);
	public String queryToJsonStr(User t,Page page);
	public BaseResponse idoUpdate(User t);
	public BaseResponse idoAdd(User t);
	public BaseResponse idoUpdatePassword(String username,String orinPassword,String newPassword);
	public BaseResponse idoUpdatePassword(String orinPassword,String newPassword);
	public User getCurrentUser();
	public String getCurrentUserName();
	public BaseResponse idoUpdateUserInfo(User t);
	public User queryById(Long id);
	public User findByName(String username);
	public User findWechatId(String wechatId);
	public long idoAddByWechat(String wechatId);
	public long idoAddByWechat(String wechatId,String roleName,String realName,String mobilePhoneNo);
	public long idoAddByWechat(String wechatId,String roleName);
	public long idoAddByQyWechat(String wechatId,String realName,String mobilePhone,String gender,String photo,String roleName,String departmentCode);
	public long idoAddByUserApplication(String userName,String realName,String mobilePhone,String gender,String photo,String roleName,String departmentCode,String email,String password);
	public User findById(Long id);
	public BaseResponse idoDelete(long id);
	public void idoUpdateAllAttr(User t);
	public BaseResponse idoResetPassword(String userName,String email);
	public HSSFWorkbook createExcel(User t);
}
